﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Enter.Common;
using System.Configuration;

namespace Enter.Config
{
    public class ImgPathConfig
    {
        /// <summary>
        /// 图片上传的根路径
        /// </summary>
        private static string ImgUpLoad = SafeConvert.ToString(ConfigurationManager.AppSettings["ImgUpLoadPath"]);

        /// <summary>
        /// 图片显示的服务器地址
        /// </summary>
        private static string ImgServer = SafeConvert.ToString(ConfigurationManager.AppSettings["ImgServer"]);

        /// <summary>
        /// 商品类型上传路径
        /// </summary>
        public static string GoodClassUploadPath = String.Format("{0}ProductCategory/", ImgUpLoad);

        /// <summary>
        /// 显示商品类型的服务器路径
        /// </summary>
        public static string GoodClassServerPath = String.Format("{0}ProductCategory/", ImgServer);

        /// <summary>
        /// 店铺Logo上传路径
        /// </summary>
        public static string ShopLogoUploadPath = String.Format("{0}shop/Logo/", ImgUpLoad);

        /// <summary>
        /// 显示店铺Logo的服务器路径
        /// </summary>
        public static string ShopLogoServerPath = String.Format("{0}shop/Logo/", ImgServer);

        /// <summary>
        /// 商品图片上传路径
        /// </summary>
        public static string productUploadPath = String.Format("{0}product/", ImgUpLoad);

        /// <summary>
        /// 显示商品图片的服务器路径
        /// </summary>
        public static string productServerPath = String.Format("{0}product/", ImgServer);
        /// <summary>
        /// 商品列表上传路径
        /// </summary>
        public static string productListUploadPath = String.Format("{0}product/list/", ImgUpLoad);

        /// <summary>
        /// 商品列表的服务器路径
        /// </summary>
        public static string productListServerPath = String.Format("{0}product/list/", ImgServer);
        /// <summary>
        /// 商品热门排行上传路径
        /// </summary>
        public static string productHotUploadPath = String.Format("{0}product/hot/", ImgUpLoad);

        /// <summary>
        /// 商品热门排行的服务器路径
        /// </summary>
        public static string productHotServerPath = String.Format("{0}product/hot/", ImgServer);
        /// <summary>
        /// 商品详情图片上传路径
        /// </summary>
        public static string productInfoUploadPath = String.Format("{0}product/info/", ImgUpLoad);

        /// <summary>
        /// 商品详情图片的服务器路径
        /// </summary>
        public static string productInfoServerPath = String.Format("{0}product/info/", ImgServer);
    }
}
